// const http = require("http");
import http from "http";
import moduleA from "./module/moduleA";

const server = http.createServer(function (request, response) {
    response.writeHeader(200, {
        'Content-Type': 'text/html;charset=utf-8'  // 添加charset=utf-8
    });
    response.end( moduleA.msg + "请求结束")
})

server.listen(3000, function () {
    console.log("服务器运行于 http://127.0.0.1:3000")
})